package com.zf.yichat.model;

import java.io.Serializable;
import java.util.Date;
import javax.persistence.*;

@Table(name = "st_goods_redeemed")
public class StGoodsRedeemed implements Serializable {

    // 已兑换
    public static final Integer STATE_REDEEMED = 0;
    // 已发货
    public static final Integer STATE_SHIPMENT = 1;

    @Id
    private Integer id;

    @Column(name = "user_id")
    private Long userId;

    @Column(name = "goods_id")
    private Integer goodsId;

    // 状态 0 已兑换  1已发货
    private Integer state;

    // 物流信息
    private String logistics;

    @Column(name = "create_time")
    private Date createTime;

    @Column(name = "shipment_time")
    private Date shipmentTime;

    private static final long serialVersionUID = 1L;

    public StGoodsRedeemed(Integer id, Long userId, Integer goodsId, Date createTime, Integer state, String logistics, Date shipmentTime) {
        this.id = id;
        this.userId = userId;
        this.goodsId = goodsId;
        this.state = state;
        this.logistics = logistics;
        this.createTime = createTime;
        this.shipmentTime = shipmentTime;
    }

    public StGoodsRedeemed() {
        super();
    }

    /**
     * @return id
     */
    public Integer getId() {
        return id;
    }

    /**
     * @param id
     */
    public void setId(Integer id) {
        this.id = id;
    }

    /**
     * @return user_id
     */
    public Long getUserId() {
        return userId;
    }

    /**
     * @param userId
     */
    public void setUserId(Long userId) {
        this.userId = userId;
    }

    /**
     * @return goods_id
     */
    public Integer getGoodsId() {
        return goodsId;
    }

    /**
     * @param goodsId
     */
    public void setGoodsId(Integer goodsId) {
        this.goodsId = goodsId;
    }

    public Integer getState() {
        return state;
    }

    public void setState(Integer state) {
        this.state = state;
    }

    public String getLogistics() {
        return logistics;
    }

    public void setLogistics(String logistics) {
        this.logistics = logistics;
    }

    /**
     * @return create_time
     */
    public Date getCreateTime() {
        return createTime;
    }

    /**
     * @param createTime
     */
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Date getShipmentTime() {
        return shipmentTime;
    }

    public void setShipmentTime(Date shipmentTime) {
        this.shipmentTime = shipmentTime;
    }
}